import { defineStore } from 'pinia'
import { store } from '@/stores'

export const useSocketStore = defineStore({
  id: 'socket',
  state: () => ({
		id: '',
		socket: null
  }),
  actions: {
		SET_SOCKET_ID(id) {
			this.id = id
		},
		SET_SOCKET(socket) {
			this.socket = socket
		}
  }
})

export function useSocketStoreHook() {
  return useSocketStore(store)
}
